<template>
	<view v-if="info" class="detail-page">
		<image :src="info.img" mode="widthFix" style="width: 100%;"></image>
		<view style="margin:20rpx;background-color: white;border-radius: 20rpx;padding: 30rpx;">
			<view style="font-size: 28rpx;" class="info">
				<view>名称：</view>
				<view style="color: black;">{{info.name || ''}}</view>
			</view>
			<view style="margin-top: 20rpx;" class="info">
				<view>联系人：</view>
				<view>{{info.contacts}} {{info.mobile}}</view>
			</view>
			<view style="margin-top: 20rpx;" class="info">
				<view>地址：</view>
				<view>{{info.address||''}}</view>
			</view>
			
		</view>
		<view style="margin:20rpx;background-color: white;border-radius: 20rpx;padding: 30rpx;">
			<view class="info">
				<view>简介：</view>
				<view>
					{{info.content || ''}}
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		components: {},
		data() {
			return {
				info: null
			}
		},
		onLoad({
			data
		}) {
			this.info = JSON.parse(data)
			console.log(this.info)
		},
		onReachBottom() {},
		methods: {

		}
	}
</script>

<style lang="scss" scoped>
	.detail-page {
		min-height: 100vh;
		background-color: #f5f5f5;
		font-size: 28rpx;
		.info {
			display: flex;

			view:nth-child(1) {
				min-width: 130rpx;
			}

			view:nth-child(2) {
				flex: 1;
				color: gray;
			}
		}
	}
</style>